<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jstl/core_rt"%>
<c:set var="ctx" value="${pageContext.request.contextPath}" />
<%@taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt_rt" %>
<jsp:include page="../inc.jsp"></jsp:include>

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
		<style type="text/css">
			table#formTb tr{
				height:30px;
				border-bottom: 1px solid green;
				margin: 5px;
			}
			table#formTb tr td:first-child{
				font-size: 18px;
				color: #2694E8;
				width: 100px;
				text-align: right;
				padding: 10px 3px;
			}
			table#formTb tr td input[text]{
				width: 250px;
			}
			
			
		</style>
		
		<script type="text/javascript">
			$(function(){
				$('#idcard').next("span").blur(function(){
					
				});
			});
			
			function checkSex(nv){
				
				var ras = $('input[type="radio"]');
				var sexn = nv.substring(16,17);
				if(sexn=='1'){
					ras[0].checked="checked";
					ras[1].checked=false;
				}
				else{
					ras[0].checked=false;
					ras[1].checked="checked";
				}
				
			}
			
			function checkBirthday(nv){
				var bir = nv.substring(6,10)+'-'+nv.substring(10,12)+'-'+nv.substring(12,14);
				$('#birthday').datebox('setValue',bir);
			}
			
		

			
		
		
		
		</script>
		
		
		
		
		
		
		
		
		
		
		
		
		
		<form id="formData">
		<div id="tt" class="easyui-tabs" fit:true border=false>   
		    <div title="基本信息" style="padding:0px;display:none;">   
		        <table id="formTb" width="100%">
					<tr>
						<td width="100px">姓名:</td>
						<td><input type="hidden" name="id" value="${pb.id}" />	
							<input class="easyui-textbox" name="name" value="${pb.name}"  data-options="
								required:true,
								validType:'chs',
								prompt:'中文的名字'
							">
						</td>
					</tr>
					<tr>
						<td>身份证号:</td>
						<td>
							<input class="easyui-textbox" value="${pb.idcard}" name="idcard" data-options="
								required:true,
								prompt:'18位身份证号码',
								
								onChange:function(nv,ov){
								    checkSex(nv);
								    checkBirthday(nv);
								}
							">
						</td>
					</tr>
					<tr>
						<td>性别:</td>
						<td>
							<input type="radio" name="sex" value="1"
							<c:if test="${pb.sex == '1' or empty pb.sex}">checked</c:if> /> 男 
							<input type="radio" name="sex" value="2"
							<c:if test="${pb.sex == '2' or empty pb.sex}">checked</c:if> />女
						</td>
					</tr>
					
					<tr>
						<td>出生日期:</td>
						<td>
							<input class="easyui-datebox" enable=false id="birthday" 
							value="<fmt:formatDate value="${pb.birthday}" pattern="yyyy-MM-dd"/>" name="birthday">
						</td>
					</tr>
					<tr>
						<td width="100px">民族:</td>
						<td>
							<input id="ecc" class="easyui-combobox" name="national"   
    					data-options="valueField:'id',textField:'name',required:true,url:'${ctx}/pmc/notional.coc'" /> 
						</td>
					</tr>
					<tr>
						<td>手机号码:</td>
						<td>
							<input class="easyui-textbox" name="tell" id="mobile"
							value="${pb.tell}"
							 data-options="
								required:true,
								prompt:'11位的手机号码'
							">
						</td>
					</tr>
						<tr>
						<td>邮箱:</td>
						<td>
							<input class="easyui-textbox" name="email" id="email"
							value="${pb.email}"
							 data-options="
								required:true,
								prompt:'邮箱'
							">
						</td>
					</tr>
					<tr>
						<td>籍贯:</td>
						<td>
						<input class="easyui-textbox" value="${pb.nplace}" name="nplace" data-options="required:true">

						</td>
					</tr>
					
					<tr>
						<td>入党时间:</td>
						<td>
							<input class="easyui-datebox" value="${pb.joinTime}" enable=false name ="joinTime"  id="joinTime" data-options="required:true"> 
						</td>
					</tr>
					<tr>
						<td>所处行业:</td>
						<td>
							<input id="ecc" class="easyui-combobox" name="industryid"   
    					data-options="required:true,valueField:'id',textField:'name',url:'${ctx}/ic/find.coc'" /> 						</td>
					</tr>
				</table>  
		    </div>   
		    <div title="拓展信息" data-options="closable:false" style="overflow:auto;padding:0px;display:none;">   
		        <table id="formTb" width="100%">
					
					<tr>
						<td>学历:</td>
						<td>
							<input class="easyui-textbox" value="${pb.education}" name="education" data-options="">
						</td>
					</tr>
					
					<tr>
						<td>转正时间:</td>
						<td>
							<input class="easyui-datebox" value="${pb.positiveTime}" name="positiveTime" enable=false id="positiveTime" >
						</td>
					</tr>
					<tr>
						<td>工作时间:</td>
						<td>
							<input class="easyui-datebox" value="${pb.workTime}" name="workTime" enable=false id="workTime"> 
						</td>
					</tr>
					<tr>
						<td>婚姻状况:</td>
						<td>
							<input class="easyui-textbox" value="${pb.marital}" name="marital" data-options="">
						</td>
					</tr>
					<tr>
						<td>入党所在:</td>
						<td>
							<input class="easyui-textbox" value="${pb.pmbranch}" name="pmbranch" data-options="">
						</td>
					</tr>
					<tr>
						<td>入党介绍人:</td>
						<td>
							<input class="easyui-textbox" value="${pb.pmr}" name="pmr" data-options="">
						</td>
					</tr>
					<tr>
						<td>党内职务:</td>
						<td>
							<input class="easyui-textbox" value="${pb.pposts}" name="pposts" data-options="">
						</td>
					</tr>
					<tr>
						<td>毕业院校:</td>
						<td>
							<input class="easyui-textbox" value="${pb.graschool}" name="graschool" data-options="">
						</td>
					</tr>
					
				</table>    
		    </div>   
		</div> 
		
	</form>
		
		
		
		
		
		
		
		
</body>
</html>